# Maintainer: Alexey Pavlov <alexpux@gmail.com>

_realname=File-Copy-Recursive
pkgname=perl-${_realname}
pkgver=0.44
pkgrel=1
pkgdesc="extension for recursively copying files and directories"
arch=('any')
license=('PerlArtistic' 'GPL')
options=('!emptydirs')
depends=('perl')
url='http://search.cpan.org/dist/File-Copy-Recursive'
groups=('perl-modules')
source=("https://www.cpan.org/authors/id/D/DM/DMUEY/${_realname}-${pkgver}.tar.gz")
sha256sums=('ae19a0b58dc1b3cded9ba9cfb109288d8973d474c0b4bfd28b27cf60e8ca6ee4')

build() {
  cd "${srcdir}/${_realname}-${pkgver}"
  PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
  make
}

check() {
  cd "${srcdir}/${_realname}-${pkgver}"
  make test
}

package() {
  cd "${srcdir}/${_realname}-${pkgver}"
  make DESTDIR="${pkgdir}" install
}
